//package com.yuan.spring.messagequeue;
//
//import com.yuan.spring.messagequeue.rabbitMq.RabbitConfig;
//import org.slf4j.Logger;
//import org.slf4j.LoggerFactory;
//import org.springframework.amqp.rabbit.core.RabbitTemplate;
//import org.springframework.beans.factory.annotation.Autowired;
//import org.springframework.data.redis.core.RedisTemplate;
//import org.springframework.web.bind.annotation.RequestMapping;
//import org.springframework.web.bind.annotation.RestController;
//
//import java.util.HashMap;
//import java.util.Map;
//
///**
// * Created by 袁恩光 on 2017/5/11.
// */
//@RestController
//public class QueueController {
//
//    private static final Logger logger = LoggerFactory.getLogger(QueueController.class);
//
//    @Autowired
//    private RabbitTemplate rabbitTemplate;
//
//    @Autowired
//    private RedisTemplate redisTemplate;
//
//    @RequestMapping("/rabbitMq")
//    public void send() {
//        Map<String, String> actionmap = new HashMap<>();
//        actionmap.put("id", "123123");
//        rabbitTemplate.convertAndSend(RabbitConfig.SFG_MESSAGE_QUEUE, actionmap);
//    }
//
//    @RequestMapping("/redisMessage")
//    public void sendRedis() {
//        redisTemplate.convertAndSend("chat", "Hello from Redis!");
//    }
//
//}
